<template>
    <!--处置过程-->
    <div class="view" :style="{ '--theme': $store.getters.themeColor }">
        <custom-title name="指挥调度过程"></custom-title>
        <el-row>
            <el-table border style="width: 100%" :data="viewDataSouse">
                <el-table-column label="调度人" prop="processName" align="center"></el-table-column>
                <el-table-column label="任务派发时间" prop="flowNodeTime" align="center"></el-table-column>
                <el-table-column label="处置人" prop="orderFileProcessName" align="center"></el-table-column>
                <el-table-column label="任务描述" prop="remark" align="center"></el-table-column>
                <el-table-column label="附件" width="80" align="center">
                    <template slot-scope="{row}">
                        <el-button type="text" size="mini" @click="seeClick(row)" v-if="row.orderFileList?.length">查看</el-button>
                    </template>
                </el-table-column>
            </el-table>
        </el-row>
    </div>
</template>

<script>
import CustomTitle from '@/components/eventManagement/Title.vue'
import EventFilePreview from '../components/EventFilePreview.js'
export default {
    name: 'disposalProcess',
    components: { CustomTitle },
    data() {
        return {
            files: {
                imgs: [],
                videos: [],
                isOpen: false
            },
            isChaoqi: '2',
            accomplish: '1'
        }
    },
    props: {
        viewDataSouse: {
            //视图数据源
            type: Array,
            default: []
        }
    },
    methods: {
        orderStatusFunc(row) {
            //处理单状态：是否完成 0处理中 1处理完成 2回退
            if (row.status != '1') {
                return '否'
            } else {
                return '是'
            }
        },
        headerCellStyle({ row, column, rowIndex, columnIndex }) {
            return (
                'background: #F8F8F8;\n' +
                'border-radius: 5px 0px 0px 0px;\n' +
                'border: 1px solid #EEEEEE;\n' +
                'font-size: 14px;\n' +
                'font-family: PingFangSC-Regular, PingFang SC;\n' +
                'font-weight: 400;\n' +
                'color: #333333;\n' +
                'height: 40px;'
            )
        },
        filesCancelFun(data) {
            this.files.isOpen = data
        },
        seeClick(row) {
            EventFilePreview.show({ files: row.orderFileList })
        }
    }
}
</script>

<style lang="scss" scoped>
$theme: var(--theme);
.view {
    height: 100%;
    background: rgba(255, 255, 255, 0.85);
    // box-shadow: 0px 10px 12px 3px rgba(213, 210, 233, 0.55);
    border-radius: 8px;
}

// .title-class {
//   display: inline-block;
// }

// .title {
//   height: 3vh;
//   background: $theme;
//   border-radius: 17px;
//   margin-top: 1vh;
//   /*margin-left: 3vh;*/
//   display: flex;
//   align-items: center;
// }

.icon {
    width: 8px;
    height: 8px;
    background: #ffffff;
    border-radius: 50%;
    margin-left: 1vh;
    margin-right: 1vh;
}

.title-name {
    font-family: PingFangSC-Regular, PingFang SC;
    font-weight: 400;
    color: #ffffff;
    line-height: 22px;
    margin-right: 2vh;
}

.titleName {
    float: left !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    width: 100%;
    font-size: 10px;
    padding: 0.3vh 0px;
    font-family: PingFangSC-Regular, PingFang SC;
    font-weight: 400;
    color: #98a0a7;
}

.value {
    float: left !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    width: 100%;
    padding: 0.3vh 0px;
    font-family: PingFangSC-Regular, PingFang SC;
    font-weight: 400;
    color: #666666;
    display: contents;
}

.el-row {
    margin-bottom: 2vh;
}

.attention {
    font-family: PingFangSC-Regular, PingFang SC;
    font-weight: 400;
    color: red;
}

/deep/ .el-radio__input.is-checked .el-radio__inner {
    border-color: #ff6a6c;
    background: #ff6a6c;
}

/deep/ .el-radio__input.is-checked + .el-radio__label {
    color: #ff6a6c;
}
</style>
